﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using StockDse.Models;
using System.Web.Mvc;

namespace StockDse.Tests.Fakes
{
    class FakeDseData
    {
        public static List<Dse> CreateTestDses()
        {

            List<Dse> Dses = new List<Dse>();

            for (int i = 0; i < 101; i++)
            {

                Dse sampleDse = new Dse()
                {
                    DseID = i,
                    Title = "Sample Dse",
                    HostedBy = "SomeUser",
                    Address = "Some Address",
                    Country = "USA",
                    ContactPhone = "425-555-1212",
                    Description = "Some description",
                    EventDate = DateTime.Now.AddDays(i),
                    Latitude = 99,
                    Longitude = -99
                };

                RSVP rsvp = new RSVP();
                rsvp.AttendeeName = "SomeUser";
                sampleDse.RSVPs.Add(rsvp);

                Dses.Add(sampleDse);
            }

            return Dses;
        }

        public static Dse CreateDse()
        {
            Dse Dse = new Dse();
            Dse.Title = "New Test Dse";
            Dse.EventDate = DateTime.Now.AddDays(7);
            Dse.Address = "5 Main Street";
            Dse.Description = "Desc";
            Dse.ContactPhone = "503-555-1212";
            Dse.HostedBy = "scottgu";
            Dse.Latitude = 45;
            Dse.Longitude = 45;
            Dse.Country = "USA";
            return Dse;
        }

        public static FormCollection CreateDseFormCollection()
        {
            var form = new FormCollection();

            form.Add("Description", "Description");
            form.Add("Title", "New Test Dse");
            form.Add("EventDate", "2010-02-14");
            form.Add("Address", "5 Main Street");
            form.Add("ContactPhone", "503-555-1212");
            return form;
        }

    }
}
